<!DOCTYPE html>
<html>
<head>
    <meta charset="UTF-8">
    <title></title>
    <meta name="viewport" content="width=device-width, initial-scale=1,maximum-scale=1, user-scalable=no">
    <meta name="apple-mobile-web-app-capable" content="yes">
    <meta name="apple-mobile-web-app-status-bar-style" content="black">
    <link rel="stylesheet" href="../../plugins/mui/mui.min.css">
    <link rel="stylesheet" href="../../css/my/security/index.css" />
    <script src="../../js/statistics.js"></script>
    <script src="../../js/fontset.js"></script>
    <style>

    </style>
</head>
<body>
<header class="mui-bar mui-bar-nav header">
    <a class="mui-action-back mui-icon mui-icon-left-nav mui-pull-left"></a>
    <h1 class="mui-title"></h1>
</header>
<div class="mui-content content-info">
	<div class="group" >
		<div class="group-item active" id="detailInfo">
			
		</div>
	</div>
	
</div>	

<script type="text/javascript" src="../../plugins/jquery/jquery-3.1.0.min.js"></script>
<script src="../../plugins/mui/mui.min.js"></script>
<!--<script type="text/javascript" src="../plugins/mui/update.js"></script>-->
<script src="../../js/getApiToken.js"></script>
<script src="../../js/md5.js"></script>
<script src="../../plugins/template/template.js" ></script>
<script src="../../js/life_housekeeper/windowTitleView.js"></script>
<script type="text/html" id="detailList">
	<ul class="mui-table-view">
		<li class="mui-table-view-cell">
			<p>身份证号：</p>
			<p>{{user.AAC002}}</p>
		</li>
		<li class="mui-table-view-cell">
			<p>参保人姓名：</p>
			<p>{{user.AAC003}}</p>
		</li>
	</ul>
	{{each list.list as item}}
	<ul class="mui-table-view">
		<li class="mui-table-view-cell">
			<p>缴纳年月：</p>
			<p>{{item.JFNY}}</p>
		</li>
		<li class="mui-table-view-cell">
			<p>缴纳基数：</p>
			<p>{{item.JFJS}}</p>
		</li>
		<li class="mui-table-view-cell">
			<p>个人缴纳：</p>
			<p>{{item.GRJN}}</p>
		</li>
		<li class="mui-table-view-cell">
			<p>单位缴纳：</p>
			<p>{{item.DWJN}}</p>
		</li>
		<li class="mui-table-view-cell">
			<p>缴纳总额：</p>
			<p>{{item.JNZJE}}</p>
		</li>
		<li class="mui-table-view-cell">
			<p>参保单位：</p>
			<p>{{item.CBDW}}</p>
		</li>
	</ul>
	{{/each}}
</script>

<script type="text/javascript">
	mui.init();	
	mui.plusReady(function(){
		var self = plus.webview.currentWebview(),
			title = self.title,
			type = self.type;
			url = "/home/Social/"+type,
			userId = plus.storage.getItem('cg_user_id');
			document.title = title;
			$(".mui-title").html(title);
			if(type){
				plus.nativeUI.showWaiting('正在查询，请稍后',{modal:false,back:'close'});
				myAjax(url,'post',{
					'userId' : userId
				},function(e){
					plus.nativeUI.closeWaiting();
					//console.log(JSON.stringify(e));
					if(e.code == 0){
						var detailInfo = document.getElementById("detailInfo"),
						detailHtml = template('detailList',e);
						detailInfo.innerHTML = detailHtml;
						
					}else{
						var msg = e.message;
						mui.toast('查询失败，'+msg);
						setTimeout(function(){
							mui.back();
						},1500);
					}
				})	
			}
		//重写back
		var back = function(){
	            self.close();
	        }
		 mui.back = function(){
			plus.nativeUI.closeWaiting();
			back();	
		}	
	})

	
</script>
</body>
</html>
